<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
    <style>
      body {
        background-color: rgb(29, 61, 243);
      }
      .water {
        background-color: #fff;
        width: 200px;
        height: 200px;
        border-radius: 50%;
        position: fixed;
        z-index: -1;
        animation: water 1s 1;
      }
      @keyframes water {
        0% {
          transform: translate(-50%, -50%) scale(0);
          opacity: 1;
          display: block;
        }
        100% {
          transform: translate(-50%, -50%) scale(1.5);
          opacity: 0;
          display: none;
        }
      }
    </style>
  </head>
  <body>
    <script>
      document.onclick = function (e) {
        var x = e.clientX
        var y = e.clientY
        var div = document.createElement('div')
        div.classList.add('water')
        div.style.top = y + 'px'
        div.style.left = x + 'px'
        document.body.appendChild(div)
        div.onanimationend = function () {
          this.parentNode.removeChild(this)
        }
      }
    </script>
  </body>
</html>
